SF-3705 Show offline message in the import from Paratext section#3702
SF-3705 Show offline message in the import from Paratext section#3702
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #3702 +/- ##
=======================================
Coverage 81.73% 81.73%
=======================================
Files 619 619
Lines 38651 38651
Branches 6317 6317
=======================================
Hits 31593 31593
Misses 6084 6084
Partials 974 974 ☔ View full report in Codecov by Sentry. |
Nateowami
left a comment
There was a problem hiding this comment.
@Nateowami reviewed 3 files and all commit messages, and made 2 comments.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on RaymondLuong3).
src/SIL.XForge.Scripture/ClientApp/src/app/checking/import-questions-dialog/import-questions-dialog.component.spec.ts line 509 at r1 (raw file):
const env = new TestEnvironment({ offline: true }); tick(); env.fixture.detectChanges();
This tick and detect changes are unneeded (already provided by the test environment).
src/SIL.XForge.Scripture/ClientApp/src/app/checking/import-questions-dialog/import-questions-dialog.component.spec.ts line 513 at r1 (raw file):
expect(env.importFromParatextButton.disabled).toBe(true); expect(env.errorMessages[1]).toEqual('Importing from Paratext is not available offline.'); env.testOnlineStatusService.setIsOnline(true);
Shouldn't this be env.setOnline(true) so the entire test environment has a consistent state? Also, it makes the tick() and env.fixture.detectChanges() that follow redundant.
728e601 to
0bdd02f
Compare
RaymondLuong3
left a comment
There was a problem hiding this comment.
@RaymondLuong3 made 2 comments.
Reviewable status: 2 of 3 files reviewed, 2 unresolved discussions (waiting on Nateowami).
src/SIL.XForge.Scripture/ClientApp/src/app/checking/import-questions-dialog/import-questions-dialog.component.spec.ts line 509 at r1 (raw file):
Previously, Nateowami wrote…
This tick and detect changes are unneeded (already provided by the test environment).
Done.
src/SIL.XForge.Scripture/ClientApp/src/app/checking/import-questions-dialog/import-questions-dialog.component.spec.ts line 513 at r1 (raw file):
Previously, Nateowami wrote…
Shouldn't this be
env.setOnline(true)so the entire test environment has a consistent state? Also, it makes thetick()andenv.fixture.detectChanges()that follow redundant.
Done.
Nateowami
left a comment
There was a problem hiding this comment.
@Nateowami reviewed 1 file and all commit messages, and resolved 2 discussions.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on RaymondLuong3).
0bdd02f to
4119081
Compare
A similar message already exists for the transcelerator option when the user was offline. I adapted the message to show in the Paratext section also.

This change is